package tc.common.utility;

import java.awt.Color;
import java.awt.Graphics;
import java.awt.Point;
import java.util.Vector;

public class DynbuffLine extends DynbuffItem {
	public Vector<Point> points = new Vector<Point>();  
	
	public void draw(Graphics g) {
		int[] xs = new int[points.size()];
		int[] ys = new int[points.size()];
		
		int i = 0;
		for (Point point : points) {
			xs[i] = point.x;
			ys[i++] = point.y;
		}
		
		Color colorOld = g.getColor();
		g.setColor(Color.BLACK);
		g.drawPolyline(xs, ys, points.size());
		g.setColor(colorOld);
	}
}
